package com.market;

import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;
import org.springframework.boot.web.servlet.FilterRegistrationBean;
import org.springframework.context.annotation.Bean;
import org.springframework.core.Ordered;
import org.springframework.web.filter.CorsFilter;

@SpringBootApplication
public class SupermarketManagementApplication {
    private static final Logger logger = LoggerFactory.getLogger(SupermarketManagementApplication.class);

    public static void main(String[] args) {
        SpringApplication.run(SupermarketManagementApplication.class, args);
        logger.info("超市管理系统启动成功！");
    }
    
    // 注释掉此CORS过滤器，因为我们使用自定义的CustomCorsFilter
    /*
    @Bean
    public FilterRegistrationBean<CorsFilter> corsFilterRegistrationBean() {
        // ... 原有代码 ...
    }
    */
}
